<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        * {
            margin: 0 auto;
        }

        .mod {
            display: inline-block;
            position: relative;
        }
        
        .img {
            width: 500px;
            height: 600px;
        }

        .f {
            display: none;
            position: absolute;
            width: 100px;
            height: 100px;
            background-color: yellow;
            opacity: 0.5;
        }

        .big {
            display: inline-block;
            border: 1px solid black;
            width: 500px;
            height: 600px;
            overflow: hidden;
            position: relative;
        }

        .bigImg {
            position: absolute;
            width: 200%;
            height: 200%;
        }
    </style>
    <script src="./js//ex003放大镜案例.js"></script>
</head>
<body>
    <div class="mod">
        <div class="f"></div>
        <img class="img" src="./images/华为荣耀.webp" alt="华为荣耀">
    </div>
    <div class="big">
        <img class="bigImg" src="./images/华为荣耀.webp" alt="华为荣耀">
    </div>
</body>
</html>